package com.zhn.evsi.service.impl;

import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
import com.zhn.evsi.client.AllianceClient;
import com.zhn.evsi.domain.dto.evsi.common.EvsiIconDTO;
import com.zhn.evsi.domain.dto.evsi.alliance.EvsiAllianceInfoDTO;
import com.zhn.evsi.domain.entity.evsi.EvsiAlliance;
import com.zhn.evsi.mapper.EvsiAllianceMapper;
import com.zhn.evsi.service.IEvsiAllianceService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import java.util.List;

@Service
public class EvsiAllianceServiceImpl extends ServiceImpl<EvsiAllianceMapper, EvsiAlliance> implements IEvsiAllianceService {

    @Autowired
    private AllianceClient allianceClient;

    /**
     * 联盟列表
     * */
    @Override
    public List<Integer> allianceList() {
        return allianceClient.allianceList();
    }

    /**
     * 获取联盟详情
     * @param allianceId - 联盟id
     * */
    @Override
    public EvsiAllianceInfoDTO alliancesInfo(Integer allianceId) {
        return allianceClient.alliancesInfo(allianceId);
    }

    /**
     * 获取联盟下属军团id
     * @param allianceId - 联盟id
     * */
    @Override
    public List<Integer> allianceCorporations(Integer allianceId) {
        return allianceClient.allianceCorporations(allianceId);
    }

    /**
     * 获取联盟图标
     * @param allianceId - 联盟id
     * */
    @Override
    public EvsiIconDTO allianceIcon(Integer allianceId) {
        return allianceClient.allianceIcon(allianceId);
    }
}
